<div class="btn-toolbar">
	<div class="btn-group">
		<?php if($associacao == null){?>
			<?php echo $this->Html->link(__('Todos'), 'javascript:void()', array('class'=>'btn btn-inverse disabled')); ?>
		<?php }else{?>
			<?php echo $this->Html->link(__('Todos'), 'lista_ordem_alfabetica', array('class'=>'btn')); ?>
		<?php }?>
		<?php foreach($associacoes as $key=>$item){?>
			<?php if($associacao == $key){?>
				<?php echo $this->Html->link($item, 'javascript:void()', array('class'=>'btn btn-inverse disabled')); ?>
			<?php }else{?>
				<?php echo $this->Html->link($item, 'lista_ordem_alfabetica/'.$key, array('class'=>'btn')); ?>
			<?php }?>
		<?php }?>
	</div>
</div>

<table class="table table-hover table-striped">
	<thead>
		<tr>
			<th><?php echo __('Categoria');?></th>
			<th><?php echo __('Nome');?></th>
			<th><?php echo __('UF');?></th>
			<th><?php echo __('Forma de Pagamento');?></th>
			<th><?php echo __('Valor')?></th>
		</tr>
	</thead>
	<tbody>
		<?php foreach($usuarios as $item){?>
			<tr>
				<td><?php echo $item['Associacao']['nome'];?></td>
				<td><?php echo $item['Usuario']['nome'];?></td>
				<td><?php echo $this->GeonameInput->findStateName($item['Endereco']['estado']);?></td>
				<td><?php echo (isset($formas_pagamento[$item['StatusAtual']['pagseguro_formas_pagamento_id']])) ? $formas_pagamento[$item['StatusAtual']['pagseguro_formas_pagamento_id']]: '-';?></td>
				<td><?php echo 'R$ '.number_format($item['Pagamento']['valor_total'], 2, ',', '.');?></td>
			</tr>
		<?php }?>
	</tbody>
</table>
<p class="text-info">
<?php
echo $this->Paginator->counter(array(
'format' => __('Página {:page} de {:pages}, total de {:count} registros')
));
?>	</p>
<div class="pagination pagination-centered">
	<ul>
		<?php echo $this->Paginator->prev(
			'< '.__('Anterior'),
			array('tag' => 'li', 'class' => 'prev'),
			'<a>< '.__('Anterior').'</a>',
			array('tag' => 'li', 'escape' => false, 'class' => 'prev disabled')
		);?>
		<?php echo $this->Paginator->numbers(array('separator' => '', 'tag'=>'li', 'currentTag'=>'a', 'currentClass'=>'active')); ?>
		<?php echo $this->Paginator->next(
			__('Próximo'). ' >',
			array('tag' => 'li', 'class' => 'prev'),
			'<a>'.__('Próximo').' ></a>',
			array('tag' => 'li', 'escape' => false, 'class' => 'prev disabled')
		);?>
	</ul>
</div>